<?php
/**
 * This is the index.ctp
 * @access public
 * @version 1.0
 */
?>
<!-- Main content -->
<section role="main" id="main">

    <!-- Header -->
    <?php echo $this->element('page_header'); ?>

    <div class="with-padding">
        <div class="columns">
            <div class="new-row-mobile twelve-columns six-columns-tablet twelve-columns-mobile">
                <h3 class="thin underline">Edit and save profile changes</h3>
                <div class="new-row-mobile eight-columns six-columns-tablet twelve-columns-mobile">
                    <form id="account-form" class="account-form" name="account-form" >
                        <fieldset class="fieldset">
                            <legend class="legend">User Info</legend>

                            <p class="button-height inline-label">
                                <label for="username" class="label">Username</label>
                                <input type="text" name="username" id="username" class="input validate[required]" value="<?php echo $authUser['username']; ?>" data-tooltip-options="{&quot;position&quot;:&quot;right&quot;}">
                            </p>
                            <p class="button-height inline-label">
                                <label for="first_name" class="label">First Name</label>
                                <input type="text" name="first_name" id="first_name" class="input validate[required]" value="<?php echo $authUser['first_name']; ?>" data-tooltip-options="{&quot;position&quot;:&quot;right&quot;}">
                            </p>
                            <p class="button-height inline-label">
                                <label for="middle_name" class="label">Middle Name</label>
                                <input type="text" name="middle_name" id="middle_name" class="input" value="<?php echo $authUser['middle_name']; ?>" data-tooltip-options="{&quot;position&quot;:&quot;right&quot;}">
                            </p>
                            <p class="button-height inline-label">
                                <label for="last_name" class="label">Last Name</label>
                                <input type="text" name="last_name" id="last_name" class="input validate[required]" value="<?php echo $authUser['last_name']; ?>" data-tooltip-options="{&quot;position&quot;:&quot;right&quot;}">
                            </p>
                            <p class="button-height inline-label">
                                <label for="reset-pass-check" class="label">Reset Password</label>
                                <input type="checkbox" name="reset-pass-check" class="switch medium" id="reset-pass-check" value="1" />
                            </p>
                            <div class="reset-password-holder" style="display: none;" id="reset-password-holder">
                                <span id="reset-password-prompt"></span>
                                <p class="button-height inline-label">
                                    <label for="old_password" class="label">Old Password</label>
                                    <input type="password" name="old_password"  id="old_password" class="validate[optional] input"/>
                                </p>
                                <p class="button-height inline-label">
                                    <label for="password_1" class="label">New Password</label>
                                    <input type="password" name="password_1"  id="password_1" class="validate[optional] input"/>
                                </p>
                                <p class="button-height inline-label">
                                    <label for="password_2" class="label">Retype Password</label>
                                    <input type="password" name="password_2"  id="password_2" class="validate[optional,equals[password_1]] input"/>
                                </p>

                                <input type="hidden" name="account_upt_id" id="account_upt_id" value="<?php echo $authUser['id']; ?>"/>
                            </div>
                            <p class="button-height inline-label">
                                <label for="save-btn" class="label">&nbsp;</label>
                                <button type="button" class="button" id="save-btn">
                                    <span class="button-icon green-gradient"><span class="icon-download"></span></span>
                                    Save
                                </button>

                                <button type="button" class="button" id="cancel-btn">
                                    <span class="button-icon anthracite-gradient"><span class="icon-cross-round"></span></span>
                                    Cancel
                                </button>
                            </p>
                        </fieldset>
                    </form>
                </div>
            </div>
        </div>
    </div>

</section>
<!-- End main content -->

<!-- Side tabs shortcuts -->
<?php echo $this->element('side_tabs_shortcuts'); ?>
<!-- Sidebar/drop-down menu -->
<?php echo $this->element('right_side_infos'); ?>

<!-- URL -->
<input type="hidden" id="update-url" value="<?php echo $this->Html->url(array('controller' => 'Users', 'action' => 'changeLogin')); ?>" />
<input type="hidden" id="logout-url" value="<?php echo $this->Html->url(array('controller' => 'Users', 'action' => 'logout')); ?>" />


<?php
echo $this->Html->script('setup.js');

/** Template functions **/
echo $this->Html->script('developr.input.js');
echo $this->Html->script('developr.message.js');
echo $this->Html->script('developr.modal.js');
echo $this->Html->script('developr.navigable.js');
echo $this->Html->script('developr.notify.js');
echo $this->Html->script('developr.scroll.js');
echo $this->Html->script('developr.progress-slider.js');
echo $this->Html->script('developr.tooltip.js');
echo $this->Html->script('developr.confirm.js');
echo $this->Html->script('developr.agenda.js');
echo $this->Html->script('developr.tabs.js');
echo $this->Html->script('libs/glDatePicker/glDatePicker.min3860.js?v=1');

echo $this->Html->script('libs/tinycon.min.js');
echo $this->Html->script('custom-scripts/dashboard.js');

echo $this->Html->script('custom-scripts/accountSettings.js');

?>